#ifndef NEURALNETWORK_H
#define NEURALNETWORK_H

/// This class manages a neural network
class NeuralNetwork
{
public:
    /// Constructor
    NeuralNetwork();

    /// Destructor
    virtual ~NeuralNetwork();

    /// Clear the network
    void clear();

    /// Create the network
    void createNetwork(int layers, int* neuronsPerLayer);

    /// Set the synaptic weight of a connection
    void setWeight(int from, int to, double weight);

    /// Run the values through the network
    bool runNetwork(double* inputs, double* outputs);

private:

    double getValue(double* inputs, int neuron);

    int _layers;
    int* _neuronsPerLayer;
    int _neurons;

    double** _weights;
};

#endif // NEURALNETWORK_H
